package com.rongc.client.freight.business.mine.buz;

import android.content.Context;

import com.rongc.client.freight.R;
import com.rongc.client.freight.base.view.widget.CJRow.ARResponse;
import com.rongc.client.freight.utils.dic.impl.Field;
import com.rongc.client.freight.utils.dic.impl.FieldConstant;
import com.rongc.client.freight.utils.dic.impl.Table;

/**
 * Created by ccqx on 2017/7/17.
 */

public class SettingBuz {
    public static Table getSettingTable(Context context) {

        Table table = new Table();
        table.addField(new Field("head", context.getResources().getString(R.string.setting_head_lable), 1, FieldConstant.SHOWTYPE_JUMP_ACTIVITY,FieldConstant.INPUTTYPE_LONG_DATE,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_DATATIMESTYLE,1,0));
        table.addField(new Field("nickname", context.getResources().getString(R.string.setting_nickname_lable), 2, FieldConstant.SHOWTYPE_JUMP_ACTIVITY,FieldConstant.INPUTTYPE_SINGLE,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_TEXTSTYLE,1,0));
        table.addField(new Field("password", context.getResources().getString(R.string.setting_password_lable), 3, FieldConstant.SHOWTYPE_JUMP_ACTIVITY,FieldConstant.INPUTTYPE_LONG_DATE,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_DATATIMESTYLE,1,0));
        table.addField(new Field("mute", context.getResources().getString(R.string.setting_mute_lable), 4, FieldConstant.SHOWTYPE_NO_CLICK,FieldConstant.INPUTTYPE_RADIO,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_DATATIMESTYLE,1,0));
        table.addField(new Field("feedback", context.getResources().getString(R.string.setting_feedback_lable), 5, FieldConstant.SHOWTYPE_JUMP_ACTIVITY,FieldConstant.INPUTTYPE_SINGLE,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_NUMBERSTYLE,1,0));
        table.addField(new Field("clear", context.getResources().getString(R.string.setting_clear_lable), 6, FieldConstant.SHOWTYPE_JUMP_ACTIVITY,FieldConstant.INPUTTYPE_SINGLE,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_TEXTSTYLE,1,0));
        table.addField(new Field("update", context.getResources().getString(R.string.setting_update_lable), 7, FieldConstant.SHOWTYPE_CLICK,FieldConstant.INPUTTYPE_LONG_DATE,FieldConstant.SHOW_MODE,FieldConstant.INPUTSTYLE_TEXTSTYLE,1,0));
        table.addField(new Field("about", context.getResources().getString(R.string.setting_about_lable), 8, FieldConstant.SHOWTYPE_JUMP_ACTIVITY,FieldConstant.INPUTTYPE_LONG_DATE,FieldConstant.EDIT_MODE,FieldConstant.INPUTSTYLE_TEXTSTYLE,2,0));

        return table;
    }

    public static ARResponse getMockBaseResponse(){
        String str = "{\"data\":{\"head\":\"\",\"nickname\":\"\"," +
                "\"password\":\"\",\"mute\":\"\",\"feedback\":\"\",\"clear\":\"\"" +
                ",\"update\":\"\",\"about\":\"\"}}";
        return new ARResponse(str);
    }
}
